package com.mvp.shq.washer.ui.news;

import com.mvp.shq.washer.entity.BaseResult;
import com.mvp.shq.washer.entity.MessageBean;
import com.mvp.shq.washer.http.Api;
import com.mvp.shq.washer.http.RxSchedulers;

import java.util.List;

import io.reactivex.Observable;

/**
 * Created by Administrator on 2017/8/24.
 */

public class NewsModel implements NewsConstract.Model {
    @Override
    public Observable<BaseResult<List<MessageBean>>> getMessages(String token, String userId) {
        return Api.getInstance().service
                .getMessages(token,userId)
                .compose(RxSchedulers.io_main());
    }
}
